package cn.hloger.spider.demo.newsDemo.enums;

/**
 * TODO
 *
 * @author huanglong
 * @Description TODO
 * @data 2022/9/18
 */
public enum WeChatEmojiEnum {
    /**
     * key
     */
    DOG("[旺柴]"),

    /**
     * key
     */
    HAPPY("[庆祝]");

    private String code;

    WeChatEmojiEnum(String code) {
        this.code = code;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public static String getEmoji(WeChatEmojiEnum weChatEmojiEnum, int count) {
        StringBuffer stringBuffer = new StringBuffer();
        if (count == 0) {
            count = 1;
        }
        for (int i = 0; i < count; i++) {
            stringBuffer.append(weChatEmojiEnum.getCode());
        }
        return stringBuffer.toString();
    }

}
